import request from '@/utils/request';

export async function queryOwnCompany() {
  return request(`/server/api/mds/d-customer/selectCompany`, {
    method: 'POST',
    body: {},
  });
}
export async function querytDictByCode(params) {
  return request(`/server/api/mds-dict-data/selectDictByCode`, {
    method: 'POST',
    body: params,
  });
}
export async function selectAreaById(params) {
  return request(`/server/api/mds-location-area/selectAreaById`, {
    method: 'POST',
    body: params,
  });
}

export async function selectOrgById(params) {
  return request(`/server/api/mds/mds-organization/selectAreaById`, {
    method: 'POST',
    body: params,
  });
}

export async function viewAreaById(params) {
  return request(`/server/api/mds/mds-location-area/viewAreaById`, {
    method: 'POST',
    body: params,
  });
}

export async function querySelectSearch(payload) {
  const { params, url } = payload;
  return request(`/server/api/${url}`, {
    method: 'POST',
    body: params,
  });
}
